package com.say.activity;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

import com.say.test.R;
import com.say.tool.Tool;

public class DemoDialogActivity extends Activity {
	/** Called when the activity is first created. */

	private Button btn_pre;
	private Button btn_next;

	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		Tool.logInfo(""+DemoDialogActivity.class.getSimpleName()+"onCreate()");
		setContentView(R.layout.layout4);

		btn_pre = (Button) findViewById(R.id.layout4_btn1);
		btn_next = (Button) findViewById(R.id.layout4_btn2);

		btn_pre.setOnClickListener(new OnClickListener() {
			public void onClick(View v) {
				Intent intent = new Intent();
				intent.setClass(DemoDialogActivity.this, MainActivity.class);
				startActivity(intent);
			}
		});
 
		btn_next.setOnClickListener(new OnClickListener() {
			public void onClick(View v) {
				Intent intent = new Intent();
				intent.setClass(DemoDialogActivity.this, DBOperateActivity.class);
				startActivity(intent);
			}
		});
	}
	
	public void onResume() {
		Tool.logInfo(""+DemoDialogActivity.class.getSimpleName()+"OnResume()");
		
		super.onResume();
	}

	public void onPause() {
		Tool.logInfo(""+DemoDialogActivity.class.getSimpleName()+"onPause()");
		super.onPause();
	}
}